<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>

<%@include file="islogin.jsp" %>
<%@ page import="com.ch7.dal.Comment" %>
<%@ page import="com.ch7.common.DataConverter" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    
    
    <title>My JSP 'comment-delete.jsp' starting page</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->
<%
Comment comment=new Comment();
int result=0;
result=comment.delete(DataConverter.toInt(request.getParameter("id")));
if(result==1){
out.println("<script>alert('博文删除成功');window.location.href='manager/comment-manage.jsp?blogid="+request.getParameter("blogid")+"';</script>");
}else{
out.println("<script>alert('博文删除失败');window.location.href='manager/comment-manage.jsp?blogid="+request.getParameter("blogid")+"';</script>");
}
 %>
  </head>
  
  <body>
  </body>
</html>
